<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class RoleList extends BaseModel
{
    use HasFactory;
    public $timestamps = false;
    protected $guarded = [];
    protected $table = 'sys_role_list';

    public function role()
    {
        return  $this->belongsTo(Role::class, "role_id");
    }

    public function scopeRelatedJoin($query)
    {
        $query->with("role");
    }
}
